package com.zjzywl.iotSendthings.repository;

import java.util.List;


import javax.transaction.Transactional;

import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Modifying;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;
import org.springframework.stereotype.Repository;

import com.zjzywl.iotSendthings.entity.JDWPBGMX;
import com.zjzywl.iotSendthings.entity.JDWPBGXX;

@Repository
public interface ProvideJDWPBGMXRepository extends JpaRepository<JDWPBGMX,Integer> {
	@Query("select u from JDWPBGMX u where u.uuid=:uuid ")
	List<JDWPBGMX> findByUuid(@Param("uuid") String uuid);
	@Modifying
	@Transactional
	@Query("update JDWPBGMX u set u.wp=:wp,u.sl=:sl,u.bz=:bz where u.uuid=:uuid AND u.num=:num ")
	void updataByUuid(@Param("wp")String wp, @Param("sl") String sl, @Param("uuid") String uuid,@Param("num") String i,@Param("bz") String bz);
}
